{% extends "home/home.html" %}

{% block content %}
<div class="row">
    <div class="col-md-4 col-md-offset-4">
        <div class="panel panel-success">
            <div class="panel-heading">
                <h3 class="panel-title"><span class="glyphicon glyphicon-plus"></span>&nbsp;会员注册</h3>
            </div>
            <div class="panel-body">
                {% for msg in get_flashed_messages(category_filter=["err"]) %}
                <p style="color:red;">{{ msg }}</p>
                {% endfor %}
                {% for msg in get_flashed_messages(category_filter=["ok"]) %}
                <p style="color:green;">{{ msg }}</p>
                {% endfor %}
                <form role="form" method="post">
                    <fieldset>
                        <div class="form-group">
                            <label for="input_name"><span class="glyphicon glyphicon-user"></span>&nbsp;{{ form.name.label }}</label>
                            {{ form.name }}
                        </div>
                        {% for err in form.name.errors %}
                        <div class="col-md-12">
                            <font style="color:red">{{ err }}</font>
                        </div>
                        {% endfor %}
                        <div class="form-group">
                            <label for="input_email"><span class="glyphicon glyphicon-envelope"></span>&nbsp;{{ form.email.label }}</label>
                            {{ form.email }}
                        </div>
                        {% for err in form.email.errors %}
                        <div class="col-md-12">
                            <font style="color:red">{{ err }}</font>
                        </div>
                        {% endfor %}
                        <div class="form-group">
                            <label for="input_phone"><span class="glyphicon glyphicon-phone"></span>&nbsp;{{ form.phone.label }}</label>
                            {{ form.phone }}
                        </div>
                        {% for err in form.phone.errors %}
                        <div class="col-md-12">
                            <font style="color:red">{{ err }}</font>
                        </div>
                        {% endfor %}
                        <div class="form-group">
                            <label for="input_password"><span class="glyphicon glyphicon-lock"></span>&nbsp;{{ form.pwd.label }}</label>
                            {{ form.pwd }}
                        </div>
                        {% for err in form.pwd.errors %}
                        <div class="col-md-12">
                            <font style="color:red">{{ err }}</font>
                        </div>
                        {% endfor %}
                        <div class="form-group">
                            <label for="input_repassword"><span
                                    class="glyphicon glyphicon-lock"></span>&nbsp;{{ form.repwd.label }}</label>
                            {{ form.repwd }}
                        </div>
                        {% for err in form.repwd.errors %}
                        <div class="col-md-12">
                            <font style="color:red">{{ err }}</font>
                        </div>
                        {% endfor %}
                        {{ form.csrf_token }}
                        {{ form.submit }}
                    </fieldset>
                </form>
            </div>
        </div>
    </div>
</div>
{% endblock %}